<?php
/**
 * User: hjd-yao
 * Date: 2019/6/3
 * Time: 9:40
 */

namespace App\Http\Controllers\Shop;


use App\Helpers\Search;
use App\Http\Controllers\BackendController;
use App\Models\Shop\ReturnGoodsModel;
use Illuminate\Http\Request;

class ReturnGoodsController extends BackendController
{

    /**
     * @title 退货订单
     * @param Request $request
     * @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View
     */
    public function returnList(Request $request)
    {
        $search = Search::make($request)->bindModel(new ReturnGoodsModel())
            ->input('goods_name','商品名称','',['filed'=>'goods_name'])
            ->bindSearchData();
        $model = $search->where();
        $list = $model->where('store_id',0)->paginate($this->getPerPageNum());
        return view('backend::shop.order.return_goods',[
            'page_title'=>'退货订单',
            'list'=>$list
        ]);
    }
}